package top.noteday.controller;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.cloud.context.config.annotation.RefreshScope;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import top.noteday.provider.VersionService;

import java.util.HashMap;
import java.util.Map;

@RestController
@RequestMapping(value = "/backstage/version")
public class VersionController {

    @Autowired
    private VersionService versionService;

    /*@Value("${kalimdor.access.port}")
    private String port;*/

    @GetMapping("/url")
    public String getUrl() {
        return versionService.getUrl("hhhhhhhhhhhhhhhhhhh");
       /* Map<String, String> map = new HashMap<>();
        map.put("aaa", "111");
        map.put("bbb", "222");
        System.out.println(port);*/
        //return port;// + versionService.demoPost(map);
    }

}
